Field
This disclosure is generally related to video encryption. More specifically, this disclosure is related to a method and system for efficiently and securely encrypting, transmitting, and decrypting image frames of a video stream based on selective encryption.
Related Art
The progress of technology includes the communication of increasing amounts of data. In the field of video streaming, in order to play video data in a remote and synchronous manner, a remote device can output images to a local device. The remote device may be a content-transmitting device, and the local device may be a content-receiving device. The remote and local devices can include a desktop computer, a mobile device such as a laptop or tablet, an embedded device, a smart television, or other computing device. In a current method of video data transfer, the transmitting device can perform data encapsulation in real time on image frames, and transmit the encapsulated image frames to the receiving device as a video stream. The receiving device can subsequently decapsulate the encapsulated image frames of the video stream to continuously display the video stream on a local display of the receiving device. In order to reduce the volume of the data transmission, the transmitting device may also encode the image frame before encapsulating and transmitting the image frame, and the receiving device may decapsulate and decode the image frame.
In a system based on, e.g., the Linux Framebuffer technology, two encryption methods may be used. In the first method, no encryption is used. The transmitting device obtains an image frame from a Framebuffer, performs video encoding and packet encapsulation, and transmits the image frame to the receiving device as an IP data packet, where no encryption process is performed. In the second method, encryption can occur at the transmission layer. The encapsulated image frame is encrypted and subsequently transmitted (e.g., based on an SSL protocol). However, in the first method (no encryption), if the transmitted data is intercepted by a malicious entity, the transmitted data may be easily obtained, which may result in a leak of private or confidential information. Furthermore, in the second method (encryption at the transmission layer), the transmitting device must encrypt each encapsulated and possibly encoded image frame, and the receiving device must decrypt each image frame. This may result in a decreased efficiency in the system.